'''
Created on 2012-9-27

@author: infear
'''
from heapq import heappush
from random import sample, shuffle
from pprint import pprint
mySets=sets=set([])
for i in xrange(0,10):
    mySets.add(i**2)
    sets.add(i)

sets.union(mySets)
print mySets==sets

heap=[]
for i in xrange(0,10):
    heappush(heap,i)

values=range(1,11)+'J,Q,K'.split(',');
suits="d,c,h,s".split(',');
cards=[(v,s) for v in values for s in suits];

print heap

print sample("sab",1)
shuffle(cards)
pprint(cards)